/* 交通数据分析页面样式 */

/* 继承全局样式 */
@import url('./index.css');

/* 顶部导航栏样式 */
.admin-header {
    height: 64px;
    background: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    position: relative;
    z-index: 100;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 32px;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-logo {
    height: 48px;
    width: auto;
    object-fit: contain;
}

.system-title {
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.breadcrumb-section .el-breadcrumb {
    font-size: 14px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.notification-badge {
    cursor: pointer;
}

.notification-badge .el-button {
    font-size: 18px;
    color: #6b7280;
    padding: 8px;
}

.notification-badge .el-button:hover {
    color: #667eea;
    background: rgba(102, 126, 234, 0.1);
}

.user-dropdown {
    cursor: pointer;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.user-info:hover {
    background: rgba(102, 126, 234, 0.1);
}

.username {
    font-weight: 500;
    color: #1f2937;
    font-size: 14px;
}

/* 侧边栏菜单选中状态 */
.sidebar-menu .el-menu-item.is-active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.sidebar-menu .el-menu-item,
.sidebar-menu .el-submenu__title {
    height: 48px;
    line-height: 48px;
    border-radius: 0 24px 24px 0;
    margin: 2px 12px 2px 0;
    color: #6b7280;
    transition: all 0.3s ease;
}

.sidebar-menu .el-menu-item:hover,
.sidebar-menu .el-submenu__title:hover {
    background: rgba(102, 126, 234, 0.1);
    color: #667eea;
}

/* 分析页面主容器 */
.analysis-container {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 分析头部 */
.analysis-header {
    background: white;
    padding: 16px;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    margin-bottom: 16px;
    transition: all 0.3s ease;
}

.analysis-header:hover {
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.15);
}

.header-title {
    font-size: 18px;
    font-weight: 600;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 12px;
}

.filter-section {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
}

.filter-section .el-button {
    transition: all 0.3s ease;
}

.filter-section .el-button--primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.2);
}

.filter-section .el-button--primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.3);
}

/* 分析卡片网格 */
.analysis-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 16px;
    margin-bottom: 16px;
}

.analysis-card {
    background: white;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.analysis-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.15);
    border-color: rgba(102, 126, 234, 0.2);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.card-title {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
}

/* 图表容器 */
.chart-container {
    height: 200px;
    position: relative;
    background: linear-gradient(to bottom, rgba(102, 126, 234, 0.02), transparent);
    border-radius: 8px;
    overflow: hidden;
}

/* 图例样式 */
.chart-legend {
    display: flex;
    gap: 16px;
    margin-top: 12px;
    flex-wrap: wrap;
    padding: 8px;
    background: rgba(102, 126, 234, 0.05);
    border-radius: 6px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: #6b7280;
    transition: all 0.3s ease;
}

.legend-item:hover {
    color: #1f2937;
}

.legend-color {
    width: 12px;
    height: 12px;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.legend-item:hover .legend-color {
    transform: scale(1.2);
}

/* 数据对比卡片 */
.comparison-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: linear-gradient(to right, rgba(102, 126, 234, 0.05), rgba(118, 75, 162, 0.05));
    border-radius: 8px;
    margin-top: 12px;
    transition: all 0.3s ease;
}

.comparison-card:hover {
    background: linear-gradient(to right, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
}

.comparison-icon {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    color: #667eea;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.2);
}

.comparison-data {
    flex: 1;
}

.comparison-value {
    font-size: 18px;
    font-weight: 600;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 2px;
}

.comparison-label {
    font-size: 12px;
    color: #6b7280;
}

/* 详细数据表格 */
.data-table-section {
    background: white;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.data-table-section:hover {
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.15);
    border-color: rgba(102, 126, 234, 0.2);
}

.table-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.table-title {
    font-size: 16px;
    font-weight: 600;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.table-actions {
    display: flex;
    gap: 8px;
}

/* 数据标签 */
.data-tag {
    display: inline-flex;
    align-items: center;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.tag-success {
    background: rgba(103, 194, 58, 0.1);
    color: #67c23a;
}

.tag-warning {
    background: rgba(230, 162, 60, 0.1);
    color: #e6a23c;
}

.tag-danger {
    background: rgba(245, 108, 108, 0.1);
    color: #f56c6c;
}

/* Element UI 组件样式覆盖 */
.el-table {
    margin-bottom: 12px;
}

.el-table th {
    background: linear-gradient(to right, rgba(102, 126, 234, 0.05), transparent);
    font-weight: 600;
}

.el-table--striped .el-table__body tr.el-table__row--striped td {
    background: rgba(102, 126, 234, 0.02);
}

.el-table__row:hover > td {
    background: rgba(102, 126, 234, 0.05) !important;
}

.el-pagination {
    margin-top: 12px;
    text-align: right;
}

.el-select:hover .el-input__inner {
    border-color: #667eea;
}

.el-select .el-input.is-focus .el-input__inner {
    border-color: #667eea;
}

/* 响应式设计 */
@media (max-width: 1200px) {
    .analysis-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .analysis-container {
        padding: 16px;
    }

    .analysis-grid {
        grid-template-columns: 1fr;
    }

    .filter-section {
        flex-direction: column;
        align-items: stretch;
    }

    .filter-section .el-select,
    .filter-section .el-button {
        width: 100%;
    }
}

/* 加载状态 */
.loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 40px;
    color: #6b7280;
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 16px;
    display: block;
}

/* 工具提示 */
.info-tooltip {
    margin-left: 4px;
    color: #667eea;
    cursor: help;
    transition: all 0.3s ease;
}

.info-tooltip:hover {
    transform: scale(1.1);
    color: #764ba2;
}
